﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="WebForm1.aspx.cs" Inherits="WebApplication2.WebForm1" %>

<!DOCTYPE html>

<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <title></title>
</head>
<body>
    <form id="form1" runat="server">
        <div>
	    <asp:Label ID="lblName" runat="server" Text="lblName"></asp:Label><asp:Button ID="btnOk" runat="server" Text="btnOk" OnClick="Button1_Click" />
        </div>
    </form>
    <script src="http://localhost:3027/Script/jquery-1.8.3.min.js"></script>
    <script src="http://localhost:3027/Script/jquery.timers-1.2.js"></script>
    <script type="text/javascript">
	$(function () {
	    $('body').everyTime('1s', function () {
		$.ajax({
		    async: false,
		    url: "Handler1.ashx",
		    data: {},
		    type: "post",
		    success(data) {
			var h1 = document.getElementById('lblName');
			h1.innerHTML = data;
		    }
		});
	    });
	});
    </script>
</body>
</html>
